﻿using System;
using System.Collections.Generic;
using System.Linq;
using GalaSoft.MvvmLight;
using SqlSugar;
namespace WebFirst.Entities
{
    /// <summary>
    /// 
    ///</summary>
    [SugarTable("MeterInfoList")]
    public class MeterInfo:ObservableObject
    {
        private int? id;
        /// <summary>
        ///  
        /// 默认值: 
        ///</summary>
        [SugarColumn(ColumnName="ID" ,IsPrimaryKey = true ,IsIdentity = true  )]
         public int? Id 
        {
            get
            {
                return id;
            }
            set
            {
                id= value;RaisePropertyChanged();
            }
        }

        private int? seqNo;
        /// <summary>
        ///  
        /// 默认值: 
        ///</summary>
        [SugarColumn(ColumnName="SeqNo"    )]
         public int? SeqNo { get { return seqNo; } set { seqNo = value;RaisePropertyChanged(); } }

        private string commuAddr;
        /// <summary>
        ///  
        /// 默认值: 
        ///</summary>
        [SugarColumn(ColumnName="CommuAddr"    )]
         public string CommuAddr { get { return commuAddr; } set { commuAddr = value;RaisePropertyChanged(); } }


        /// <summary>
        ///  
        /// 默认值: 
        ///</summary>
        private int? baudrate;
        [SugarColumn(ColumnName="Baudrate"    )]
         public int? Baudrate { get { return baudrate; } set { baudrate = value;RaisePropertyChanged(); } }
        /// <summary>
        ///  
        /// 默认值: 
        ///</summary>
        ///
        private int? protocolType;
        [SugarColumn(ColumnName="ProtocolType"    )]
         public int? ProtocolType { get { return protocolType; } set { protocolType = value;RaisePropertyChanged(); } }
        /// <summary>
        ///  
        /// 默认值: 
        ///</summary>
        ///
        private string port;
        [SugarColumn(ColumnName="Port"    )]
         public string Port { get { return port; } set { port = value;RaisePropertyChanged(); } }
        /// <summary>
        ///  
        /// 默认值: 
        ///</summary>
        ///
        private string commuCode;
        [SugarColumn(ColumnName = "CommuCode")]
        public string CommuCode { get { return commuCode; } set { commuCode = value; RaisePropertyChanged(); } }
        /// <summary>
        ///  
        /// 默认值: 
        ///</summary>
        ///
        private string tarriffNum;
        [SugarColumn(ColumnName="TarriffNum"    )]
         public string TarriffNum { get { return tarriffNum; } set { tarriffNum = value;RaisePropertyChanged(); } }
        /// <summary>
        ///  
        /// 默认值: 
        ///</summary>
        ///
        private string userType;
        [SugarColumn(ColumnName="UserType"    )]
         public string UserType { get { return userType; } set { userType = value;RaisePropertyChanged(); } }
        /// <summary>
        ///  
        /// 默认值: 
        ///</summary>
        ///
        private int? wireMode;
        [SugarColumn(ColumnName="WireMode"    )]
         public int? WireMode { get { return wireMode; } set { wireMode = value;RaisePropertyChanged(); } }
        /// <summary>
        ///  
        /// 默认值: 
        ///</summary>
        ///
        private string ratedVoltage;
        [SugarColumn(ColumnName="RatedVoltage"    )]
        
         public string RatedVoltage { get { return ratedVoltage; } set { ratedVoltage = value;RaisePropertyChanged(); } }
        /// <summary>
        ///  
        /// 默认值: 
        ///</summary>
        ///
        private string ratedCurrent;
        [SugarColumn(ColumnName="RatedCurrent"    )]
         public string RatedCurrent { get { return ratedCurrent; } set { ratedCurrent = value;RaisePropertyChanged(); } }
        /// <summary>
        ///  
        /// 默认值: 
        ///</summary>
        ///
        private string collectAddr;
        [SugarColumn(ColumnName="CollectAddr"    )]
         public string CollectAddr { get { return collectAddr; } set { collectAddr = value;RaisePropertyChanged(); } }
        /// <summary>
        ///  
        /// 默认值: 
        ///</summary>
        ///
        private string assetNumber;
        [SugarColumn(ColumnName="AssetNumber"    )]
         public string AssetNumber { get { return assetNumber; } set { assetNumber = value;RaisePropertyChanged(); } }
        /// <summary>
        ///  
        /// 默认值: 
        ///</summary>
        ///
        private string pt;
        [SugarColumn(ColumnName="PT"    )]
         public string Pt { get { return pt; } set { pt = value;RaisePropertyChanged(); } }
        /// <summary>
        ///  
        /// 默认值: 
        ///</summary>
        ///
        private string ct;
        [SugarColumn(ColumnName="CT"    )]
         public string Ct { get { return ct; } set { ct = value;RaisePropertyChanged(); } }

        private bool? isSelect;
        [SugarColumn(IsIgnore = true)]
        public bool? IsSelect
        {
            get
            {
                if (isSelect == null)
                {
                    isSelect = false;
                }
                return isSelect;
            }
            set
            {
                isSelect = value; RaisePropertyChanged();
            }
        }

    }
}
